
{% extends "dashboard.html" %}

{% block content %}

    <form action="" method="post" novalidate class="form-horizontal" enctype="multipart/form-data">
        {% csrf_token %}

        {% for field in form_obj %}

        <div class="form-group {% if field.errors %} has-error {% endif %}">
                
                <label for="{{ field.id_for_label }}" class="col-sm-2 control-label">{{ field.label }}</label>
                <label class="control-label" for="{{ field.id_for_label }}">{{ field.errors.0 }}</label>
                <div class="col-sm-8">
                    {{ field }}
                </div>
            </div>

        {% endfor %}

        <div class="form-group">
            <div class="col-sm-offset-2 col-sm-10">
                <button type="submit" class="btn btn-default">提交</button>
            </div>
        </div>

    </form>
{% endblock content %}
